import { ORDERS } from '../consts.js'
import axios from '../axios.js'
export default {
    
    // 获取我负责的所有订单
    getMyOrders(params) {
        return axios({
            url: ORDERS + "/getMyOrders",
            params
        })
    },


    // 查看订单详情
    getOrdersById(params) {
        return axios({
            url: ORDERS + "/getOrdersById",
            params
        })

    },


    // 修改订单
    updateOrder(data) {
        return axios({
            url: ORDERS + "/updateOrder",
            method: 'post',
            data
        })
    },


    // 删除订单
    delOrder(data) {
        return axios({
            url: ORDERS + "/delOrder",
            method: 'post',
            data
        })
    },

    
    // 退保申请处理
    cancelOrder(data) {
        return axios({
            url: ORDERS + "/cancelOrder",
            method: 'post',
            data
        })
    },

    //获取所有
    getAllOrders(params){
        return axios({
            url:ORDERS + "/getAllOrders",
            method:'get',
            params,
        })
    }
}